<?xml version="1.0" encoding="ascii"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
          "DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
  <title>pygoogledesktop.PyGDS</title>
  <link rel="stylesheet" href="epydoc.css" type="text/css" />
  <script type="text/javascript" src="epydoc.js"></script>
</head>

<body bgcolor="white" text="black" link="blue" vlink="#204080"
      alink="#204080">
<!-- ==================== NAVIGATION BAR ==================== -->
<table class="navbar" border="0" width="100%" cellpadding="0"
       bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="middle">

  <!-- Tree link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Index link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Help link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Project homepage -->
      <th class="navbar" align="right" width="100%">
        <table border="0" cellpadding="0" cellspacing="0">
          <tr><th class="navbar" align="center"
            ><a class="navbar" target="_top" href="http://code.google.com/p/pythongoogledesktop/">PyGoogleDesktop</a></th>
          </tr></table></th>
  </tr>
</table>
<table width="100%" cellpadding="0" cellspacing="0">
  <tr valign="top">
    <td width="100%">
      <span class="breadcrumbs">
        <a href="pygoogledesktop-module.html">Module&nbsp;pygoogledesktop</a> ::
        Class&nbsp;PyGDS
      </span>
    </td>
    <td>
      <table cellpadding="0" cellspacing="0">
        <!-- hide/show private -->
        <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink"
    onclick="toggle_private();">hide&nbsp;private</a>]</span></td></tr>
        <tr><td align="right"><span class="options"
            >[<a href="frames.html" target="_top">frames</a
            >]&nbsp;|&nbsp;<a href="pygoogledesktop.PyGDS-class.html"
            target="_top">no&nbsp;frames</a>]</span></td></tr>
      </table>
    </td>
  </tr>
</table>
<!-- ==================== CLASS DESCRIPTION ==================== -->
<h1 class="epydoc">Class PyGDS</h1><p class="nomargin-top"><span class="codelink"><a href="pygoogledesktop-pysrc.html#PyGDS">source&nbsp;code</a></span></p>
<center>
<center>  <map id="uml_class_diagram_for_pygoogle" name="uml_class_diagram_for_pygoogle">
<area shape="rect" href="pygoogledesktop.PyGDS&#45;class.html#__init__" title="x.__init__(...) initializes x; see x.__class__.__doc__ for signature" alt="" coords="17,36,727,55"/>
<area shape="rect" href="pygoogledesktop.PyGDS&#45;class.html#EnableDebug" title="pygoogledesktop.PyGDS.EnableDebug" alt="" coords="17,55,727,74"/>
<area shape="rect" href="pygoogledesktop.PyGDS&#45;class.html#DisableDebug" title="pygoogledesktop.PyGDS.DisableDebug" alt="" coords="17,74,727,92"/>
<area shape="rect" href="pygoogledesktop.PyGDS&#45;class.html#RegisterAppQueryAPI" title="Register your application with GoogleDestkopSearch engine." alt="" coords="17,92,727,111"/>
<area shape="rect" href="pygoogledesktop.PyGDS&#45;class.html#UnRegisterApp" title="UnRegister your application with GoogleDestkopSearch engine." alt="" coords="17,111,727,130"/>
<area shape="rect" href="pygoogledesktop.PyGDS&#45;class.html#DoQuery" title="Perform a simple query using the cookie passed into it." alt="" coords="17,130,727,148"/>
<area shape="rect" href="pygoogledesktop.PyGDS&#45;class.html#DoQueryHTTP" title="DoQueryHTTP uses the GDS webserver interface and returns results in XML." alt="" coords="17,148,727,167"/>
<area shape="rect" href="pygoogledesktop.PyGDS&#45;class.html#CheckSuffix" title="Checks the suffix since before Python 2.5 doesn&#39;t have the tuple check for  string method &quot;endswith&quot;." alt="" coords="17,167,727,186"/>
<area shape="rect" href="pygoogledesktop.PyGDS&#45;class.html#SendHTTPRequest" title="Send the url to Google Desktop Search Engine" alt="" coords="17,186,727,204"/>
<area shape="rect" href="pygoogledesktop.PyGDS&#45;class.html#ParseHTTPResults" title="Parse the xml results into a list" alt="" coords="17,204,727,223"/>
<area shape="rect" href="pygoogledesktop.PyGDS&#45;class.html" title="PyGDS is the main interface into the Google Desktop Search Engine." alt="" coords="16,11,728,224"/>
</map>
  <img src="uml_class_diagram_for_pygoogle.gif" alt='' usemap="#uml_class_diagram_for_pygoogle" ismap="ismap" class="graph-without-title" />
</center>
</center>
<hr />
<p>PyGDS is the main interface into the Google Desktop Search Engine.  
  It's designed to simplify interactions with GDS, instead of laying out 
  the complete bare interface to GDS.</p>

<!-- ==================== INSTANCE METHODS ==================== -->
<a name="section-InstanceMethods"></a>
<table class="summary" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td colspan="2" class="table-header">
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
      <tr valign="top">
        <td align="left"><span class="table-header">Instance Methods</span></td>
        <td align="right" valign="top"
         ><span class="options">[<a href="#section-InstanceMethods"
         class="privatelink" onclick="toggle_private();"
         >hide private</a>]</span></td>
      </tr>
    </table>
  </td>
</tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pygoogledesktop.PyGDS-class.html#__init__" class="summary-sig-name">__init__</a>(<span class="summary-sig-arg">self</span>)</span><br />
      x.__init__(...) initializes x; see x.__class__.__doc__ for signature</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pygoogledesktop-pysrc.html#PyGDS.__init__">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a name="EnableDebug"></a><span class="summary-sig-name">EnableDebug</span>(<span class="summary-sig-arg">self</span>)</span></td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pygoogledesktop-pysrc.html#PyGDS.EnableDebug">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a name="DisableDebug"></a><span class="summary-sig-name">DisableDebug</span>(<span class="summary-sig-arg">self</span>)</span></td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pygoogledesktop-pysrc.html#PyGDS.DisableDebug">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pygoogledesktop.PyGDS-class.html#RegisterAppQueryAPI" class="summary-sig-name">RegisterAppQueryAPI</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">guid</span>,
        <span class="summary-sig-arg">desc</span>,
        <span class="summary-sig-arg">readOnly</span>)</span><br />
      Register your application with GoogleDestkopSearch engine.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pygoogledesktop-pysrc.html#PyGDS.RegisterAppQueryAPI">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pygoogledesktop.PyGDS-class.html#UnRegisterApp" class="summary-sig-name">UnRegisterApp</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">guid</span>)</span><br />
      UnRegister your application with GoogleDestkopSearch engine.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pygoogledesktop-pysrc.html#PyGDS.UnRegisterApp">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pygoogledesktop.PyGDS-class.html#DoQuery" class="summary-sig-name">DoQuery</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">cookie</span>,
        <span class="summary-sig-arg">searchStr</span>,
        <span class="summary-sig-arg">category</span>=<span class="summary-sig-default">None</span>,
        <span class="summary-sig-arg">relevance</span>=<span class="summary-sig-default">False</span>)</span><br />
      Perform a simple query using the cookie passed into it.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pygoogledesktop-pysrc.html#PyGDS.DoQuery">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pygoogledesktop.PyGDS-class.html#DoQueryHTTP" class="summary-sig-name">DoQueryHTTP</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">searchStr</span>,
        <span class="summary-sig-arg">numResults</span>=<span class="summary-sig-default">10</span>,
        <span class="summary-sig-arg">category</span>=<span class="summary-sig-default">None</span>,
        <span class="summary-sig-arg">relevance</span>=<span class="summary-sig-default">False</span>,
        <span class="summary-sig-arg">rawXMLReturn</span>=<span class="summary-sig-default">False</span>,
        <span class="summary-sig-arg">extension</span>=<span class="summary-sig-default">None</span>)</span><br />
      DoQueryHTTP uses the GDS webserver interface and returns results in 
      XML.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pygoogledesktop-pysrc.html#PyGDS.DoQueryHTTP">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pygoogledesktop.PyGDS-class.html#CheckSuffix" class="summary-sig-name">CheckSuffix</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">testStr</span>,
        <span class="summary-sig-arg">suffix</span>)</span><br />
      Checks the suffix since before Python 2.5 doesn't have the tuple 
      check for string method &quot;endswith&quot;.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pygoogledesktop-pysrc.html#PyGDS.CheckSuffix">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pygoogledesktop.PyGDS-class.html#SendHTTPRequest" class="summary-sig-name">SendHTTPRequest</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">url</span>)</span><br />
      Send the url to Google Desktop Search Engine</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pygoogledesktop-pysrc.html#PyGDS.SendHTTPRequest">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pygoogledesktop.PyGDS-class.html#ParseHTTPResults" class="summary-sig-name">ParseHTTPResults</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">results</span>,
        <span class="summary-sig-arg">category</span>,
        <span class="summary-sig-arg">extension</span>)</span><br />
      Parse the xml results into a list</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pygoogledesktop-pysrc.html#PyGDS.ParseHTTPResults">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
  <tr>
    <td colspan="2" class="summary">
    <p class="indent-wrapped-lines"><b>Inherited from <code>object</code></b>:
      <code>__delattr__</code>,
      <code>__getattribute__</code>,
      <code>__hash__</code>,
      <code>__new__</code>,
      <code>__reduce__</code>,
      <code>__reduce_ex__</code>,
      <code>__repr__</code>,
      <code>__setattr__</code>,
      <code>__str__</code>
      </p>
    </td>
  </tr>
</table>
<!-- ==================== PROPERTIES ==================== -->
<a name="section-Properties"></a>
<table class="summary" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td colspan="2" class="table-header">
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
      <tr valign="top">
        <td align="left"><span class="table-header">Properties</span></td>
        <td align="right" valign="top"
         ><span class="options">[<a href="#section-Properties"
         class="privatelink" onclick="toggle_private();"
         >hide private</a>]</span></td>
      </tr>
    </table>
  </td>
</tr>
  <tr>
    <td colspan="2" class="summary">
    <p class="indent-wrapped-lines"><b>Inherited from <code>object</code></b>:
      <code>__class__</code>
      </p>
    </td>
  </tr>
</table>
<!-- ==================== METHOD DETAILS ==================== -->
<a name="section-MethodDetails"></a>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td colspan="2" class="table-header">
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
      <tr valign="top">
        <td align="left"><span class="table-header">Method Details</span></td>
        <td align="right" valign="top"
         ><span class="options">[<a href="#section-MethodDetails"
         class="privatelink" onclick="toggle_private();"
         >hide private</a>]</span></td>
      </tr>
    </table>
  </td>
</tr>
</table>
<a name="__init__"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">__init__</span>(<span class="sig-arg">self</span>)</span>
    <br /><em class="fname">(Constructor)</em>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pygoogledesktop-pysrc.html#PyGDS.__init__">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>x.__init__(...) initializes x; see x.__class__.__doc__ for 
  signature</p>
  <dl class="fields">
    <dt>Overrides:
        object.__init__
        <dd><em class="note">(inherited documentation)</em></dd>
    </dt>
  </dl>
</td></tr></table>
</div>
<a name="RegisterAppQueryAPI"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">RegisterAppQueryAPI</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">guid</span>,
        <span class="sig-arg">desc</span>,
        <span class="sig-arg">readOnly</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pygoogledesktop-pysrc.html#PyGDS.RegisterAppQueryAPI">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Register your application with GoogleDestkopSearch engine. This is 
  only required if you want to use the &quot;DoQuery&quot; function of this
  interface. Don't need to register if you use DoQueryHTTP.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>guid</code></strong> - guidgen.exe param of your application</li>
        <li><strong class="pname"><code>desc</code></strong> - a dictionary of the description 'title' = the name of your app 
          'description' = desription of the app 'icon' = icon of your app</li>
        <li><strong class="pname"><code>readOnly</code></strong> - Are going to be doing read only queries? True = yes, False = no</li>
    </ul></dd>
    <dt>Returns:</dt>
        <dd>the cookie from the query registration</dd>
  </dl>
</td></tr></table>
</div>
<a name="UnRegisterApp"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">UnRegisterApp</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">guid</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pygoogledesktop-pysrc.html#PyGDS.UnRegisterApp">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>UnRegister your application with GoogleDestkopSearch engine.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>guid</code></strong> - guidgen.exe param of your application</li>
    </ul></dd>
    <dt>Returns:</dt>
        <dd>true if it unregistered</dd>
  </dl>
</td></tr></table>
</div>
<a name="DoQuery"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">DoQuery</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">cookie</span>,
        <span class="sig-arg">searchStr</span>,
        <span class="sig-arg">category</span>=<span class="sig-default">None</span>,
        <span class="sig-arg">relevance</span>=<span class="sig-default">False</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pygoogledesktop-pysrc.html#PyGDS.DoQuery">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Perform a simple query using the cookie passed into it. This cookie 
  must be unencrypted at this point for the GoogleDesktop to know what it 
  is.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>cookie</code></strong> - the cookie returned during registration of your app with GDS.</li>
        <li><strong class="pname"><code>searchStr</code></strong> - the string used to search on</li>
        <li><strong class="pname"><code>category</code></strong> - filter the results based on a category. Valid values are 
          Email,Web,Im,File,Contact,Calendar,Task,Note, or Journal</li>
        <li><strong class="pname"><code>relevance</code></strong> - - sort by relevance (True) or recency (False)</li>
    </ul></dd>
    <dt>Returns:</dt>
        <dd>a list of tuple results (uri,content) - None if something went 
          wrong</dd>
  </dl>
<div class="fields">      <p><strong>Note:</strong>
        if the content is not retrievable, None will be in it's place.  
        Check to make sure the data is valid.
      </p>
</div></td></tr></table>
</div>
<a name="DoQueryHTTP"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">DoQueryHTTP</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">searchStr</span>,
        <span class="sig-arg">numResults</span>=<span class="sig-default">10</span>,
        <span class="sig-arg">category</span>=<span class="sig-default">None</span>,
        <span class="sig-arg">relevance</span>=<span class="sig-default">False</span>,
        <span class="sig-arg">rawXMLReturn</span>=<span class="sig-default">False</span>,
        <span class="sig-arg">extension</span>=<span class="sig-default">None</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pygoogledesktop-pysrc.html#PyGDS.DoQueryHTTP">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>DoQueryHTTP uses the GDS webserver interface and returns results in 
  XML.  However, this function will parse the XML into a more user friendly
  formatted list for looking at the results.  In the future this will 
  become a cross platform function.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>searchStr</code></strong> - the text you want to search.  Note, if you specify a string with 
          spaces in between words this will be interpreted as multiple 
          words to search.</li>
        <li><strong class="pname"><code>numResults</code></strong> - The number of results you want returned from this query. Default 
          = 10, if 0 specified, then return all!</li>
        <li><strong class="pname"><code>category</code></strong> - filter the results based on a category. Valid values are 
          email,web,im,file,contact,calendar,task,note, or journal</li>
        <li><strong class="pname"><code>relevance</code></strong> - sort by relevance (True) or recency (False) (Not implemented)</li>
        <li><strong class="pname"><code>rawXMLReturn</code></strong> - return the results in raw XML format (yes = True, no = False)</li>
        <li><strong class="pname"><code>extension</code></strong> - Only used for category = file.  Specify the file extensions to be
          searched, separate extension by comma (cpp,hpp,txt,html)</li>
    </ul></dd>
    <dt>Returns:</dt>
        <dd>This will return either raw xml for you to parse or an tuple with
          number of times it found your search term and a python list with 
          the location of the resources matching the search term</dd>
  </dl>
</td></tr></table>
</div>
<a name="CheckSuffix"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">CheckSuffix</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">testStr</span>,
        <span class="sig-arg">suffix</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pygoogledesktop-pysrc.html#PyGDS.CheckSuffix">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Checks the suffix since before Python 2.5 doesn't have the tuple check
  for string method &quot;endswith&quot;.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>testStr</code></strong> - you're test string</li>
        <li><strong class="pname"><code>suffix</code></strong> - the file extension you're testing to see is at the end of the 
          string</li>
    </ul></dd>
    <dt>Returns:</dt>
        <dd>True if it is in there, False if not</dd>
  </dl>
</td></tr></table>
</div>
<a name="SendHTTPRequest"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">SendHTTPRequest</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">url</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pygoogledesktop-pysrc.html#PyGDS.SendHTTPRequest">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Send the url to Google Desktop Search Engine</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>url</code></strong> - the uniform resource locator</li>
    </ul></dd>
    <dt>Returns:</dt>
        <dd>raw xml results</dd>
  </dl>
</td></tr></table>
</div>
<a name="ParseHTTPResults"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">ParseHTTPResults</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">results</span>,
        <span class="sig-arg">category</span>,
        <span class="sig-arg">extension</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pygoogledesktop-pysrc.html#PyGDS.ParseHTTPResults">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Parse the xml results into a list</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>results</code></strong> - the xml results from the HTTP Query</li>
        <li><strong class="pname"><code>category</code></strong> - what kind of item were you wanting to retrieve</li>
        <li><strong class="pname"><code>extension</code></strong> - what file extension are you looking for if the categor is 'file'</li>
    </ul></dd>
    <dt>Returns:</dt>
        <dd>number of times the search words were found, list of the parsed 
          results</dd>
  </dl>
</td></tr></table>
</div>
<br />
<!-- ==================== NAVIGATION BAR ==================== -->
<table class="navbar" border="0" width="100%" cellpadding="0"
       bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="middle">

  <!-- Tree link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Index link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Help link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Project homepage -->
      <th class="navbar" align="right" width="100%">
        <table border="0" cellpadding="0" cellspacing="0">
          <tr><th class="navbar" align="center"
            ><a class="navbar" target="_top" href="http://code.google.com/p/pythongoogledesktop/">PyGoogleDesktop</a></th>
          </tr></table></th>
  </tr>
</table>
<table border="0" cellpadding="0" cellspacing="0" width="100%%">
  <tr>
    <td align="left" class="footer">
    Generated by Epydoc 3.0.1 on Fri Apr 04 23:08:55 2008
    </td>
    <td align="right" class="footer">
      <a target="mainFrame" href="http://epydoc.sourceforge.net"
        >http://epydoc.sourceforge.net</a>
    </td>
  </tr>
</table>

<script type="text/javascript">
  <!--
  // Private objects are initially displayed (because if
  // javascript is turned off then we want them to be
  // visible); but by default, we want to hide them.  So hide
  // them unless we have a cookie that says to show them.
  checkCookie();
  // -->
</script>
</body>
</html>
